<?php 

namespace app\common\validate\department;

use think\Validate;

class DepartmentPosition extends Validate 
{ 
    protected $rule = [
        'position_name' => 'require',
        'code_no' => 'require',
        'department_id' => 'require',
    ];

    protected $message = [
        'position_name.require' => '请输入岗位名称',
        'code_no.require' => '请输入岗位编码',
        'department_id.require' => '请输入所属部门',
    ];

    protected $scene = [
        'edit' => ['position_name','code_no','department_id','order_num','admin_name','id'],
        'add' => ['position_name','code_no','department_id','order_num','admin_name'],
    ];

} 
